#include "SQLCurrentUserExpr.h"
#include "../visitor/SQLASTVisitor.h"

SQLCurrentUserExpr::SQLCurrentUserExpr()
{
}

// @Override
void SQLCurrentUserExpr::accept0(SQLASTVisitor_ptr v)
{
  v->visit(SharedObject(SQLCurrentUserExpr));
  v->endVisit(SharedObject(SQLCurrentUserExpr));
}

// @Override
bool SQLCurrentUserExpr::equals(Object_ptr o)
{
  if (o == nullptr)
  {
    return false;
  }

  if (this == o.get())
  {
    return true;
  }

  return getClass() == o->getClass();
}

// @Override
int SQLCurrentUserExpr::hashCode()
{
  return 0;
}

SQLObject_ptr SQLCurrentUserExpr::clone()
{
  SQLObject_ptr clone_tmp = std::shared_ptr<SQLCurrentUserExpr>(new SQLCurrentUserExpr());
  std::shared_ptr<SQLCurrentUserExpr> clone_res = std::dynamic_pointer_cast<SQLCurrentUserExpr>(clone_tmp);
  return clone_res;
}
